<?php
include_once "db.php";
	
	if (is_numeric($_GET[callid])){
    mysql_query ("DELETE FROM Calls WHERE Call_ID = '$_GET[callid]'");
	}
	$noteExist = mysql_query ("SELECT COUNT(*) from resolution_notes WHERE call_ID = '$_GET[callid]'");
	if ($noteExist > 0){
	mysql_query ("DELETE from resolution_notes WHERE call_ID = '$_GET[callid]'");
	}
 	header("Location: calls.php?active=1" );
  
?>